package com.bangdream.michelia.view.adapter;


import android.widget.ImageView;

import com.bangdream.michelia.R;
import com.bangdream.michelia.entity.courses.CoursesBean;
import com.bangdream.michelia.utils.ImageLoadUtils;
import com.chad.library.adapter.base.BaseQuickAdapter;
import com.chad.library.adapter.base.BaseViewHolder;

/**
 * Created by zhouyi on 2018/3/25.
 */

public class CourseItemAdapter extends BaseQuickAdapter<CoursesBean,BaseViewHolder> {
    public CourseItemAdapter(int layoutResId) {
        super(layoutResId);
    }

    @Override
    protected void convert(BaseViewHolder helper, CoursesBean item) {
        ImageLoadUtils.ImageLoad(mContext,item.getFaceUrl(),(ImageView) helper.getView(R.id.ivIcon),R.mipmap.kecheng);

        helper.setText(R.id.tvTitle,item.getName()+"");
//        helper.setText(R.id.tvText,Html.fromHtml(item.getIntroduction())+"");
        helper.setText(R.id.tvText,item.getTitle()+"");
    }
}
